package com.dao;

import com.entity.Admin;
import com.page.PageInfo;

import java.util.List;

public interface AdminDao {
    public Admin getByAdid(String adid);
    public List<Admin> getAll();
    public List<Admin> getAllByPage(PageInfo pageInfo);
    public List<Admin> searchNameByPage(PageInfo pageInfo,String adname);
    /**
     * 根据主键查询
     * @param adid
     * @return
     */
    public Admin getAdminByAdid(String adid);

    /**
     * 添加一个实体
     * @param admin
     * @return
     */
    public int addAdmin(Admin admin);
    /**
     * 修改实体
     */
    public int updateAdmin(Admin admin);
    public int updateAdminByExample(Admin admin);

    /**
     * 删除一个实体
     * @param adid
     * @return
     */
    public int deleteAdminByPrimayKey(String adid);

    /**
     * 删除实体根据示例
     * @return
     */
    public int deleteAdminByExample();
}
